﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using LinqKit;

namespace Nexterday.Linq.Autocompiler
{
    public class ComplexityCalculatingExpressionVisitor : ExpressionVisitor
    {
        int _complexity = 0;

        public int Complexity
        {
            get { return _complexity; }
        }
        public override System.Linq.Expressions.Expression Visit(System.Linq.Expressions.Expression exp)
        {
            _complexity++;
            return base.Visit(exp);
        }
    }
}
